// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';

/** addBiProducts POST /api/biProducts/add */
export async function addBiProductsUsingPost(
  body: API.BiProductsAddRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseLong_>('/api/biProducts/add', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** deleteBiProducts POST /api/biProducts/delete */
export async function deleteBiProductsUsingPost(
  body: API.DeleteRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseBoolean_>('/api/biProducts/delete', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** getBiProductsById GET /api/biProducts/get */
export async function getBiProductsByIdUsingGet(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getBiProductsByIdUsingGETParams,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseBiProducts_>('/api/biProducts/get', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** getMyBiProductsServiceUsages GET /api/biProducts/get/service/usages */
export async function getMyBiProductsServiceUsagesUsingGet(options?: { [key: string]: any }) {
  return request<API.BaseResponseServiceUsage_>('/api/biProducts/get/service/usages', {
    method: 'GET',
    ...(options || {}),
  });
}

/** getBiProductsVOById GET /api/biProducts/get/vo */
export async function getBiProductsVoByIdUsingGet(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getBiProductsVOByIdUsingGETParams,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseBiProductsVO_>('/api/biProducts/get/vo', {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}

/** listBiProductsByPage POST /api/biProducts/list/page */
export async function listBiProductsByPageUsingPost(
  body: API.BiProductsQueryRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponsePageBiProducts_>('/api/biProducts/list/page', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** listBiProductsVOByPage POST /api/biProducts/list/page/vo */
export async function listBiProductsVoByPageUsingPost(
  body: API.BiProductsQueryRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponsePageBiProductsVO_>('/api/biProducts/list/page/vo', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** placeAnOrder POST /api/biProducts/placeAnOrder */
export async function placeAnOrderUsingPost(
  body: API.PlaceAnOrderRequest,
  options?: { [key: string]: any },
) {
  return request<string>('/api/biProducts/placeAnOrder', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}

/** updateBiProducts POST /api/biProducts/update */
export async function updateBiProductsUsingPost(
  body: API.BiProductsUpdateRequest,
  options?: { [key: string]: any },
) {
  return request<API.BaseResponseBoolean_>('/api/biProducts/update', {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
    },
    data: body,
    ...(options || {}),
  });
}
